#ifndef REVIEW_UI_PROXY_H
#define REVIEW_UI_PROXY_H

#include <sdbus-c++/sdbus-c++.h>
#include <functional>
#include <thread>

class ReviewUIProxy
{
  public:
    ReviewUIProxy();
    virtual ~ReviewUIProxy();
    void Boot();
    std::function<std::vector<long>()> funcGetAllTaskList;
    std::function<std::vector<long>()> funcGetHandleFinishRecordList;
    std::function<std::vector<long>(long task_id)> funcGetHandleFinishRecordListWithTask;
    std::function<std::vector<long>(long task_id)> funcGetRecordList;
    std::function<std::tuple<std::string/*task_name*/,std::string/*create_time*/>(long task_id)> funcGetTaskInf;
    std::function<std::tuple<long/*stu_id*/,std::string/*create time*/,std::string/*record path*/>(long rec_id)> funcGetRecordInf;
    std::function<std::vector<std::string>()> funcGetCameraIDList;
    std::function<bool(long,std::string)> funcOutputData;
  private:
    std::unique_ptr<sdbus::IConnection> conn;
    std::unique_ptr<sdbus::IObject> obj;
    std::thread workThread;
    const char* InterfaceName="org.HBTY.ReviewUI";
};

#endif
